package fr.uniscol.model;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

import fr.uniscol.siecle.model.MEF;

public class Scolarite implements Serializable {

	private Eleve eleve = null;
	
	private Periode periode = null;
	
	private MEF mef = null;
	
	private List<Structure> structures = null;
	
	private List<Option> options = null; 
	
	public Scolarite() {
		super();
	}

	public Scolarite(Eleve eleve, Periode periode){
		this.eleve = eleve;
		this.periode = periode;
	}
	
	public String getId(){
		return eleve.getId() + "-" + periode.getCode();
	}
	
	public void setId(String id){
	}

	public Eleve getEleve() {
		return eleve;
	}

	public void setEleve(Eleve eleve) {
		this.eleve = eleve;
	}

	public Periode getPeriode() {
		return periode;
	}

	public void setPeriode(Periode periode) {
		this.periode = periode;
	}

	public MEF getMef() {
		return mef;
	}

	public void setMef(MEF mef) {
		this.mef = mef;
	}
	
	public List<Structure> getStructures() {
		if(structures == null){
			structures = new ArrayList<Structure>();
		}
		return structures;
	}

	public void setStructures(List<Structure> structures) {
		this.structures = structures;
	}

	public List<Option> getOptions() {
		if(options == null){
			options = new ArrayList<Option>();
		}
		return options;
	}

	public void setOptions(List<Option> options) {
		this.options = options;
	}
}
